package org.csmzxy.class2333;

public class Work01Car {
    private String brand;
    private String model;
    private String engine;
    public Work01Car(){
        System.out.println("调用无参构造方法，无法为属性赋初始值");
    }
    public Work01Car(String brand,String model,String engine){
        this.brand = brand;
        this.model = model;
        this.engine = engine;
    }
    public void print(){
        System.out.println("该汽车的品牌为：" + brand);
        System.out.println("该汽车的型号为：" + model);
        System.out.println("该汽车的品发动机为：" + engine);
    }
}
